<%@ page language="java" import="java.util.*,com.netjava.pojo.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>夺金网--后台显示产品</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->

  </head>

  <body>
     <table width="880" height="20" align="center">
    <tr>
	<td align="left">
	<form action="${contextPath }/product.do?operation=getByProName" method="POST" enctype="multipart/form-data">
	<input type="text" id="productName" name="productName"/>
	<input type="submit" name="submit" value="查找"/>
	</form>
	</td>
	<td align="right">
	<form action="${contextPath }/jsp/addProduct.jsp" method="get">
	<input type="submit" name="submit" value="添加商品"/>
	</form>
	</td>
	</tr>
	</table>
	<table><tr>
	<td width="100%" height="150" valign="top" background="${contextPath }/jsp/images/bg_15.gif">
	    <table width="880" height="15" align="center">
		 <tr>
		     <td><img src="${contextPath }/jsp/images/${imgSrc }" width="880">
		     </td>
	       </tr>
		</table>
		
		<table width="880" height="40" align="center"> 
		   <tr>
		     <td width="15%" align="center">商品图片</td>
		     <td width="35%" align="center">商品名称</td>
		     <td width="15%" align="center">最新价格</td>
		     <td width="20%" align="center">最后竞价会员</td>
		     <td width="15%" align="center">倒计时</td>
		   </tr>
		</table>
		  
		<c:forEach var="product" items="${productList }">
		
		<table background="${contextPath }/jsp/images/bg_22.gif" width="880" align="center" height="80">
		   <tr height="5"><td>&nbsp;</td></tr>
		   <tr>
		     <td width="15%" height="80" align="center">
		   	   <table width="125" border="0" cellpadding="0" cellspacing="0" class="product_lPaniel">
					<tr>
						<td align="center" background="${contextPath }/jsp/images/bg_13.gif">
						<table>
						<tr>
						<td>
							<img src="${contextPath }/jsp/proimages/${product.product.image1 }" alt="" width="80" height="60" border="0" style="cursor:pointer;"/>
						</td>
						</tr>
						<tr>
						<td>
						<a href="${contextPath }/product.do?operation=change&productId=${product.product.productId}&remark=${remark }">修改</a>
						<a href="${contextPath }/product.do?operation=delete&productId=${product.product.productId}&remark=${remark }" onClick="return confirm('您确定要删除此商品吗？')">删除</a>
						</td>
						</tr>
						</table>
						</td>
					</tr>
			   </table>
		     </td>
		     <td width="35%" align="center">${product.product.productName }</td>
		     <td width="15%" align="center">${product.product.currentPrice }￥</td>
		     <td width="20%" align="center">${aucUser[product.product.productId] }</td>
		     <td width="15%" align="center">${remainTime[product.product.productId] }</td>
		   </tr>
		</table>	
		<table>
		   <tr><td align="center" background="${contextPath }/jsp/images/bg_15.gif">&nbsp;</td></tr>
		</table>	
		</c:forEach>	
	
	</td>
  </tr>
 
  </table>
  </body>
</html>
